const express = require("express");
const router = express();
const config = require("./config");

const base_url = "http://" + config.IP + ":" + config.PORT + "/images/banner/";

router.get("/", (req, res) => {

    console.log(`来了。。。`);

    var data = {
        "code" : "0000",
        "message" : "success",
        "data" : [
            { 
                "image" : base_url + "1.png",
            },
            { 
                "image" : base_url + "2.png",
            },
            { 
                "image" : base_url + "3.png",
            },
            { 
                "image" : base_url + "4.png",
            }
        ]
    };
    res.send(data);
});

module.exports = router;